import { SerializeStream } from "../../Framework/Serialize/SerializeStream";
import { MarshalException } from "../../Engine/RMI/MarshalException";
type int = number;
//class EChatType

export class EChatType {
  constructor(arg1: int) {
    this.__value = arg1;
    return;
  }

  public static convert(arg1: int): EChatType {
    return new EChatType(arg1);
  }

  public value(): int {
    return this.__value;
  }

  public __write(arg1: SerializeStream): void {
    arg1.writeByte(this.__value);
    return;
  }

  public static __read(arg1: SerializeStream): EChatType {
    var loc1 = arg1.readByte();
    if (loc1 < 0 || loc1 >= 31) {
      throw new MarshalException();
    }
    return EChatType.convert(loc1);
  }

  public static /* const */ _EChatTypeWorld: int = 1;

  public static /* const */ _EChatTypeCamp: int = 2;

  public static /* const */ _EChatTypePrivate: int = 3;

  public static /* const */ _EChatTypeTrumpet: int = 4;

  public static /* const */ _EChatTypeSpace: int = 5;

  public static /* const */ _EChatTypeTeam: int = 6;

  public static /* const */ _EChatTypeGuild: int = 7;

  public static /* const */ _EChatTypeSystem: int = 8;

  public static /* const */ _EChatTypeRumor: int = 9;

  public static /* const */ _EChatTypeVCampOne: int = 10;

  public static /* const */ _EChatTypeVCampTwo: int = 11;

  public static /* const */ _EChatTypeVCampThree: int = 12;

  public static /* const */ _EChatTypeBattleFiled: int = 13;

  public static /* const */ _EChatTypeGuildPrivate: int = 14;

  public static /* const */ _EChatTypeGuildRoll: int = 17;

  public static /* const */ _EChatTypeArena: int = 18;

  public static /* const */ _EChatTypePeaceField: int = 19;

  public static /* const */ _EChatTypeForce: int = 20;

  public static /* const */ _EChatTypeMarket: int = 21;

  public static /* const */ _EChatTypeCrossStair: int = 22;

  public static /* const */ _EChatTypeCrossGroup: int = 23;

  public static /* const */ _EChatTypeCrossCopy: int = 24;

  public static /* const */ _EChatTypeEatBeans: int = 25;

  public static /* const */ _EChatTypeFightInfo: int = 26;

  public static /* const */ _EChatTypePlant: int = 27;

  public static /* const */ _EChatTypeGuildGroup: int = 28;

  public static /* const */ _EChatTypeGuildUnion: int = 29;

  public static /* const */ _EChatTypeDominion: int = 30;

  public static /* const */ _EChatTypeGuildWar: int = 16;

  public static /* const */ _EChatTypeCopy: int = 15;

  public /* var */ __value: int;
}
